@@ -2581,6 +2581,114 @@ arv_camera_gv_set_packet_size_adjustment (ArvCamera *camera, ArvGvPacketSizeAdju
25812581 arv_gv_device_set_packet_size_adjustment (ARV_GV_DEVICE (priv -> device ), adjustment );
25822582}
25832583
2584+ /**
2585+ * arv_camera_gv_configure_action_command:
2586+ * @camera: a #ArvCamera
2587+ * @command_name: the action command that will be configured (1-based)
2588+ * @device_key: a user defined 'password' that will be used to authorize action commands
2589+ * @group_key: a user defined group that will have to match for an action command
2590+ * @group_mask: a bit field that gets matched to a mask in the action command
2591+ * @error: a #GError placeholder, %NULL to ignore
2592+ *
2593+ * Configure a camera to accept action commands
2594+ *
2595+ * Since: 0.8.7
2596+ */
2597+
2598+ void
2599+ arv_camera_gv_configure_action_command (ArvCamera * camera , const char * command_name ,
2600+ guint32 device_key , guint32 group_key , guint32 group_mask , GError * * error )
2601+ {
2602+ GError * local_error = NULL ;
2603+
2604+ g_return_if_fail (arv_camera_is_gv_device (camera ));
2605+
2606+ if (error == NULL )
2607+ arv_camera_set_string (camera , "ActionSelector" , command_name , & local_error );
2608+ if (error == NULL )
2609+ arv_camera_set_integer (camera , "ActionDeviceKey" , device_key , & local_error );
2610+ if (error == NULL )
2611+ arv_camera_set_integer (camera , "ActionGroupKey" , group_key , & local_error );
2612+ if (error == NULL )
2613+ arv_camera_set_integer (camera , "ActionGroupMask" , group_key , & local_error );
2614+
2615+ if (local_error != NULL )
2616+ g_propagate_error (error , local_error );
2617+ }
2618+
2619+ /**
2620+ * arv_camera_gv_get_available_action_commands:
2621+ * @camera: a #ArvCamera
2622+ * @n_commands: (out): number of action commands
2623+ * @error: a #GError placeholder, %NULL to ignore
2624+ *
2625+ * Returns: (array length=n_commands) (transfer container): a newly allocated array of strings, which must be freed
2626+ * using g_free().
2627+ *
2628+ * Since: 0.8.7
2629+ */
2630+
2631+ const char * *
2632+ arv_camera_gv_get_available_action_commands (ArvCamera * camera , guint * n_commands , GError * * error )
2633+ {
2634+ return arv_camera_dup_available_enumerations_as_strings (camera , "ActionSelector" , n_commands , error );
2635+ }
2636+
2637+ /**
2638+ * arv_camera_gv_issue_action_command:
2639+ * @device_key: a user defined 'password' that will be used to authorize action commands
2640+ * @group_key: a user defined group that will have to match for an action command
2641+ * @group_mask: a bit field that gets matched to a mask in the action command
2642+ * @broadcast_address: the address the action command is sent to
2643+ * @inet_addresses: (out): a placeholder for an array of acknowledge IP adresses
2644+ * @n_acknowledges: (out): a placeholder for the number of ackowledges
2645+ * @error: a GError placeholder, %NULL to ignore
2646+ *
2647+ * Issue action command
2648+ *
2649+ * Returns: %TRUE if successfull
2650+ *
2651+ * Since: 0.8.7
2652+ */
2653+
2654+ gboolean
2655+ arv_camera_gv_issue_action_command (guint32 device_key , guint32 group_key , guint32 group_mask ,
2656+ GInetAddress * broadcast_address ,
2657+ GInetAddress * * inet_addresses , guint * n_acknowledges , GError * * error )
2658+ {
2659+ return arv_gv_device_issue_scheduled_action_command (device_key , group_key , group_mask ,
2660+ 0 , broadcast_address ,
2661+ inet_addresses , n_acknowledges , error );
2662+ }
2663+
2664+ /**
2665+ * arv_camera_gv_issue_scheduled_action_command:
2666+ * @device_key: a user defined 'password' that will be used to authorize action commands
2667+ * @group_key: a user defined group that will have to match for an action command
2668+ * @group_mask: a bit field that gets matched to a mask in the action command
2669+ * @timestamp_ns: action time, in nanosecond
2670+ * @broadcast_address: the address the action command is sent to
2671+ * @inet_addresses: (out): a placeholder for an array of acknowledge IP adresses
2672+ * @n_acknowledges: (out): a placeholder for the number of ackowledges
2673+ * @error: a GError placeholder, %NULL to ignore
2674+ *
2675+ * Issue action command
2676+ *
2677+ * Returns: %TRUE if successfull
2678+ *
2679+ * Since: 0.8.7
2680+ */
2681+
2682+ gboolean
2683+ arv_camera_gv_issue_scheduled_action_command (guint32 device_key , guint32 group_key , guint32 group_mask ,
2684+ guint64 timestamp_ns , GInetAddress * broadcast_address ,
2685+ GInetAddress * * inet_addresses , guint * n_acknowledges , GError * * error )
2686+ {
2687+ return arv_gv_device_issue_scheduled_action_command (device_key , group_key , group_mask ,
2688+ timestamp_ns , broadcast_address ,
2689+ inet_addresses , n_acknowledges , error );
2690+ }
2691+
25842692/**
25852693 * arv_camera_is_uv_device:
25862694 * @camera: a #ArvCamera
0 commit comments