Summary of the invention
The technical problem to be solved in the present invention provides a kind of portable Flash playing device and based on the interactive system and the method for this device, can realize the interactive function between the Flash content, and prior art has more flexibility and interactivity relatively
In order to address the above problem, the invention provides a kind of portable Flash playing device, comprise the user operation unit of the operation information that is used to receive the user; Be used to store the Flash data storage cell of Flash played file; The operation information that is used for receiving according to described user operation unit is carried out the micro-control unit of the content in the corresponding Flash played file of Flash data storage cell; And be used for the communication unit of communication, it is characterized in that:
Described micro-control unit also be used for when described operation information correspondence be the network interaction order time, control described communication unit and receive and dispatch this network interaction order successively, set up interactive network with other portable Flash playing device.
Further, described network interaction order comprises:
1) order of network is created in request;
2) request adds the order of network;
3) order of request establishment incident network;
4) acquisition request is created the order of the device tabulation of incident network;
5) request adds the order of incoming event network;
The described communication unit of described micro-control unit controls is received and dispatched this network interaction order successively, comprises to set up interactive network with other portable Flash playing device:
Described micro-control unit is when sending order 1 by described communication unit) time, be used for described portable Flash playing device as network creation side;
Described micro-control unit is when receiving order 2 by described communication unit) time, be used to other portable Flash playing devices that add the network that this portable Flash playing device created to distribute addresses;
Described micro-control unit is when receiving order 3 by described communication unit) time, being used to generate a device of creating the incident network and tabulating, this tabulation comprises title, address, incident network type and state of each device of establishment incident network;
Described micro-control unit is when receiving order 4 by described communication unit) time, be used to provide the device of described establishment incident network to tabulate to the requesting party;
Described micro-control unit is when receiving order 5 by described communication unit) time, be used for setting up network and be connected with the requesting party.
Further, described network interaction order also comprises:
The order of the interactive network device tabulation of the incident network that 6) acquisition request added;
7) request adds the order of described interactive network;
Described micro-control unit also is used for when having created the incident network and having received order 5 by described communication unit) time generate the tabulation of interactive network device, described interactive network device tabulation comprises Flash playing device title and the corresponding address information thereof that adds the present event network;
Described micro-control unit is when receiving order 6 by described communication unit) time, be used to provide described interactive network device to tabulate to the requesting party;
Described micro-control unit is when receiving order 7 by described communication unit) time, be used for setting up network and be connected with the requesting party.
Further, described portable Flash playing device also comprises the A/D converting unit;
User operation unit receives user's operation information and exports a voltage signal;
Described A/D converting unit is used for receiving described voltage signal under the control of described micro-control unit, and is converted into corresponding position information;
Described micro-control unit is according to the content in the corresponding Flash played file of this positional information execution.
Further, described positional information is a coordinate figure.
Further, described communication unit comprises Zigbee or bluetooth or infrared or WiFi communication module;
Described communication unit is connected with described micro-control unit by Serial Peripheral Interface (SPI).
The present invention also provides a kind of interactive system based on the portable Flash playing device, it is characterized in that, comprising:
At least two portable Flash playing devices;
Described portable Flash playing device includes:
Be used to store the Flash data storage cell of Flash played file;
Be used to receive the user operation unit of user's operation information;
The communication unit that is used for communication; And
Micro-control unit, the operation information that is used for receiving according to described user operation unit is carried out the content in the corresponding Flash played file of Flash data storage cell; Also be used for when described operation information correspondence be the network interaction order time, control described communication unit and receive and dispatch this network interaction order successively, set up interactive network with other portable Flash playing device.
Further, described network interaction order comprises:
1) order of network is created in request;
2) request adds the order of network;
3) order of request establishment incident network;
4) acquisition request is created the order of the device tabulation of incident network;
5) request adds the order of incoming event network;
The micro-control unit of creating in the portable Flash playing device of network also is used for receiving order 2) back distributes the address for the portable Flash playing device that adds network, and receiving order 3) the back device tabulation that generates an establishment incident network, and receiving order 4) after, provide the device of described establishment incident network to tabulate to the requesting party; The device tabulation of described establishment incident network comprises title, address, incident network type and the state of each device of establishment incident network;
Micro-control unit in the portable Flash playing device of establishment incident network also is used for receiving order 5) time, set up network with the requesting party and be connected;
Carry out 1 successively) to 5) the network interaction order, the portable Flash playing device is promptly set up man-to-man interactive network relation with the portable Flash playing device of creating the incident network.
Further, when the Flash playing device of creating the incident network and multiple arrangement had been set up interactive network and concerned, described network interaction order also comprised:
The order of the interactive network device tabulation of the incident network that 6) acquisition request added;
7) request adds the order of described interactive network;
Micro-control unit in the portable Flash playing device of establishment incident network also is used for receiving order 5) time generates the tabulation of interactive network device and comprises Flash playing device title and the corresponding address information thereof that adds the present event network; And receiving order 6) time, provide described interactive network device to tabulate to the requesting party;
Micro-control unit in the portable Flash playing device also is used for receiving order 7) time, set up network with the requesting party and be connected;
Carry out 1 successively) to 5) the network interaction order after, continue to carry out 7 successively) to 8) the network interaction order, the portable Flash playing device promptly with the incident network in all or part of portable Flash playing device set up the interactive network relation of one-to-many.
Further, described communication unit is meant alternately by wireless network and other portable Flash playing device under the control of described micro-control unit:
Described control unit sends the Flash playing device of corresponding control request signal to correspondence successively according to the control of described micro-control unit, obtains the address of interactive network device and sends the request order, to set up interactive network; And to the address transceive data of the interactive network device that obtains, thereby carry out the Flash interactive operation; Also be used to receive and set up network with the requesting party when request adds the order of incoming event network or interactive network and be connected.
Further, described portable Flash playing device also comprises: the A/D converting unit;
User operation unit receives user's operation information and exports a voltage signal;
Described A/D converting unit is used for receiving described voltage signal under the control of described micro-control unit, and is converted into corresponding position information;
Described micro-control unit is according to the content in the corresponding Flash played file of this positional information execution.
Further, described positional information is a coordinate figure.
Further, described communication unit comprises Zigbee or bluetooth or infrared or WiFi communication module;
Described communication unit is connected with described micro-control unit by Serial Peripheral Interface (SPI).
The present invention also provides a kind of and carried out mutual method in the described interactive system of claim 7, it is characterized in that, comprising:
A, reception user's operation information; According to the content in the corresponding Flash played file of the operation information execution that is received; When described operation information correspondence be the network interaction order time execution in step B;
Undertaken alternately by wireless network between B, portable Flash playing device.
Further, described step B specifically comprises:
B1, a portable Flash playing device are created network;
B2, other portable Flash playing device add network;
Portable Flash playing device in B3, the network is created the incident network, generates a device of creating the incident network simultaneously and tabulates;
When the Flash playing device of B4, adding network wants to add an incident network, obtain the device tabulation of establishment incident network earlier, and according to the address information in the incident of the establishment network device list, obtain the address of the Flash playing device of a certain establishment incident network, and to its its incident network of creating of request adding, thereby set up man-to-man interactive network relation;
B5, to the address transceive data of the interactive network device that obtains, carry out that Flash is interactive to be play.
Further, when the Flash playing device of creating the incident network and multiple arrangement have been set up interactive network and have been concerned, behind the described step B4, also comprise before the step B5:
101) receive the interactive network device tabulation that the described Flash playing device that adds the incoming event network requests generates the present event network, comprise the Flash playing device title and the corresponding address information thereof of the incident network that adds the establishment of this Flash playing device;
When 102) the Flash playing device that adds the incoming event network is wanted to add interactive network, obtain the interactive network device tabulation of the incident network that is added, and according to this interactive network device list information, obtain the appropriate address of other Flash playing devices that add this incident network, and all or part of request connection in these Flash playing devices, to set up the interactive network relation of one-to-many.
Further, in the described steps A, the content of carrying out in the corresponding Flash played file according to this operation information comprises:
Receive user's operation information and export a voltage signal; Described voltage signal is converted to corresponding position information; According to the content in the corresponding Flash played file of this positional information execution.
Further, described positional information is a coordinate figure.
Technical scheme of the present invention can be separated the Flash content design with mancarried device, make between the user and can make different Flash contents as recreation, chat and teaching courseware etc. according to oneself needs flexible design, and carry out interaction by short distance communication, thereby realized the interactive function between the Flash content, prior art has more flexibility and interactivity relatively.And the cost of manufacture of Flash content is low, and animation effect is abundant, has good market prospects.
Embodiment
Below in conjunction with drawings and Examples technical scheme of the present invention is described in detail.
See also Fig. 1, it is a specific embodiment that the present invention is based on the interactive system of portable Flash playing device, Flash playing device interactive system of the present invention comprises at least two portable Flash playing devices 10 and 20, and described portable Flash playing device 10 comprises: user operation unit 11, A/D converting unit 12, micro-control unit 13, communication unit 14, Flash data storage card 15; Can also comprise Flash video output unit 16 and audio output unit 17; Described portable Flash playing device 20 is identical with the structure of Flash playing device 10, comprise: user operation unit 21, A/D converting unit 22, micro-control unit 23, communication unit 24, Flash data storage card 25, can also comprise Flash video output unit 26 and audio output unit 27.
Described user operation unit 11 provides a User Interface, is used for the input of interactive information, is used to receive user's operation information, and exports a voltage signal; Preferable selection is a touch-screen, and the user can be shone upon corresponding button in the Flash played file by touch screen operation.
Described A/D converting unit 12 connects described user operation unit 11, and be used under the control of described micro-control unit 13 receiving described voltage signal, and it is carried out analog/digital conversion, obtaining a corresponding position information, such as: coordinate parameters (x, y).
Described micro-control unit 13, connect described A/D converting unit, be used for receiving successively described positional information, as coordinate parameters (x, y), and carry out in the Flash data storage card 15 content in the corresponding Flash played file successively according to this positional information, if correspondingly in the Flash played file be the network interaction order then control communication unit 14 and undertaken alternately by wireless network and other portable Flash playing device.Also be used for loading the Flash played file and playing, send video data, send voice data to audio output unit to the Flash video output unit from Flash storage card 15.
Described communication unit 14, connect described micro-control unit (such as connecting) by the serial peripheral equipment interface SPI serial ports, be used for sending the Flash playing device of corresponding control request signal successively to correspondence according to the control of described micro-control unit, obtain the address of interactive network device and send the request order, to set up interactive network; And to the address transceive data of the interactive network device that obtains, thereby carry out the Flash interactive operation.
Described Flash data storage card 15 is used to store the Flash played file; Described Flash played file can be that user oneself makes; This Flash played file can but be not limited to store with the form of SWF, this storage card can be non-volatile memory mediums such as SD card or USB flash disk.This storage card can be fixed in the portable Flash playing device, also can be the plug type storage card.
Described Flash video output unit 16 and audio output unit 17 are respectively applied for the demonstration of Flash video and the synchronous playing of audio signal.
Wherein, described network interaction order comprises:
A: the order of network is created in request, and the Flash playing device that is about to first request establishment network is as main frame, and other Flash playing devices then add the slave that this creates network as request; Be that first request is created micro-control unit in the Flash playing device of network when sending this order by described communication unit, be used for described portable Flash playing device as network creation side.
B: request adds the order of network, and when receiving this request command, the micro-control unit in the described main frame will distribute the appropriate address of corresponding a plurality of Flash playing devices; Generate one simultaneously and comprise that the request of device name and corresponding address information thereof adds the tabulation of the Flash playing device of this network;
C: the order of request establishment incident network, any one or several Flash playing devices (comprising main frame) of promptly having added network that described main frame creates are initiatively created an incident network to the host request of place network, and can set and allow other Flash playing devices that added the networks that described main frame creates to add;
When receiving this request command, the micro-control unit in the main frame also is used to generate a device of creating the incident network tabulates, and comprises title, address, incident network type and state of each device of establishment incident network.
D: acquisition request is created the order of the device tabulation of incident network;
Receiving the micro-control unit that this acquisition request creates in the Flash playing device of incident network device list also is used to provide the device of described establishment incident network to tabulate to the requesting party.
E: request adds the order of incoming event network, promptly according to the address information of creating the Flash playing device in the incident network device list, obtain the address of the Flash playing device of a certain establishment incident network, and to its its incident network of creating of request adding, to set up man-to-man interactive network relation;
Receiving this request adds micro-control unit in the Flash playing device of incoming event networking command and also is used for setting up network with requesting party's Flash playing device and is connected, and generate the interactive network device tabulation of present event network, comprise the Flash playing device title and the corresponding address information thereof that add the incident network that this Flash playing device creates.
When interactive system when device is formed more than two, then may be when request adds a certain incident network, the corresponding Flash playing device of creating this incident network has been set up the interactive network relation with multiple arrangement, therefore can also comprise to issue orders:
F: the order of the interactive network device tabulation of the incident network that acquisition request added;
Receiving the micro-control unit that this acquisition request creates in the Flash playing device of incident network device list also is used to provide described interactive network device to tabulate to the requesting party.
G: request adds the order of the interactive network of place incident network, promptly according to described interactive network device list information, obtain the appropriate address of other Flash playing device that adds this incident network, and all or part of request connection in these Flash playing devices, to set up the interactive network relation of one-to-many;
Receiving this request adds micro-control unit in the Flash playing device of interactive network order and also is used for setting up network with requesting party's Flash playing device and is connected.
When set up one to one or the interactive network of one-to-many relation after, in order to carry out interaction, also comprise to issue orders with the interactive network device of having set up the interactive network relation:
H: the order of transceive data, the micro-control unit in the Flash playing device carries out interaction by the address transceive data of communication unit to the interactive network device that obtains.
Wherein, a and b order are to be used to create a network annexation, promptly constitute a network annexation by short-distance wireless communication modes such as Zigbee or bluetooths;
C is used to create the incident network, promptly by an incident network platform to host request foundation, as: the chess game in the recreation, chatting platform, teaching platform etc.;
D, e and f, g then are to utilize the described incident network platform to carry out interactive network annexation, and as being connected of chess game, chatroom and interactive teaching and learning, different is, d, e are man-to-man interactive relationship, and f, g then are the interactive relationship of one-to-many.
Wherein, described portable flash playing device is embedded mobile device as mobile phone, PDA, MP4, PMP, multimedia player, ELA learning machine etc.
Wherein, described communication unit can be Zigbee, bluetooth, infrared or WiFi communication module.
The present invention also provides a kind of portable Flash playing device, comprises user operation unit, A/D converting unit, micro-control unit, communication unit, Flash data storage card, can also comprise the Flash video output unit, and audio output unit; Each part as mentioned before.
See also Fig. 2 and be of the present invention at the above-mentioned flow chart that carries out mutual method in based on the interactive system of portable Flash playing device, its step comprises:
Step 10: micro-control unit loads the Flash played file from the Flash storage card---plays frame by frame as the SWF file.In the Flash playing process, can send the frame that data show current broadcast, send the data output sound to audio output unit to the Flash video output unit;
Step 20: user operation unit receives the customer interaction information of input successively; Micro-control unit controls A/D converting unit is changed the interactive information that user operation unit received successively, to obtain corresponding position information---such as coordinate parameters (x, y); For example: the user carries out alternately with in progress Flash by " click " operation, and the user can click to fetch to swf between MovieClip object in the screen or Button object and send " order ", the broadcast of indirect control swf and the switching of frame; Micro-control unit controls A/D converting unit with user's click information be converted to coordinate figure (x, y);
Step 30: micro-control unit is carried out content in the corresponding Flash played file successively according to described positional information, and send the Flash playing device of corresponding control request signal successively to correspondence according to the network interaction order in this content control communication unit, obtain the address of interactive network device, to set up interactive network.For example: (x y) sends to the Flash playing program to micro-control unit, handles corresponding ActionScript script by the Flash playing program with coordinate figure; Micro-control unit sends the Flash playing device of corresponding control request signal to correspondence successively according to the network interaction order control communication unit of writing in the script, and the address that obtains the interactive network device is to set up interactive network.
In the lump referring to Fig. 3, be the described flow chart of setting up interactive network of step 30 among Fig. 2 please, wherein, the described interactive network of setting up comprises following concrete steps:
Step 302: create network, as main frame, other Flash playing devices then add the slave of this establishment network as request with first Flash playing device of asking to create network;
Step 304: add network, Flash playing device request as slave adds the network that main frame is created, the appropriate address of the corresponding a plurality of Flash playing devices as slave of host assignment generates one simultaneously and comprises that the request of device name and corresponding address information thereof adds the tabulation of the device of network;
Step 306: create the incident network, an incident network is created in the arbitrary Flash playing device request that adds network described in the step 302, and this incident network allows other Flash playing devices to add, and the device tabulation of incident network is created in main frame generation simultaneously;
Step 308: when the Flash playing device of adding network wants to add an incident network, obtain the device tabulation of establishment incident network earlier, and according to the address information in the incident of the establishment network device list, obtain the address of the Flash playing device of a certain establishment incident network, and to its its incident network of creating of request adding, thereby set up man-to-man interactive network relation.
Receive and describedly add the Flash playing device of incoming event network requests and requesting party's Flash playing device connects, and generate the interactive network device tabulation of present event network, comprise the Flash playing device title and the corresponding address information thereof that add the incident network that this Flash playing device creates.
Wherein, when interaction systems when device is formed more than two, then may be when request adds a certain incident network, the corresponding device of creating this incident network has been set up the interactive network relation with multiple arrangement, therefore also comprises:
Step 310: when the Flash playing device that adds the incoming event network is wanted to add interactive network, obtain the incident network interdynamic network device list that is added earlier, and according to this interactive network device list information, obtain the appropriate address of the Flash playing device that adds this incident network, and all or part of request connection in these Flash playing devices, to set up the interactive network relation of one-to-many;
Receiving micro-control unit in the Flash playing device of this request command and requesting party's Flash playing device connects.
Step 40: micro-control unit carries out the interactive broadcast of Flash by the address transceive data of communication unit to the interactive network device that obtains.Being connected by corresponding interface (as SPI) between micro-control unit and the communication unit realizes, micro-control unit sends the Flash playing device of corresponding control request signal to appointment according to different trigger commands by communication unit, and judge whether to receive data by communication unit, just the data that receive are handled if receive data.
Further be illustrated with an application example of the present invention below.
Seeing also Fig. 4, is flash playing device interactive system schematic diagram of the present invention, and as shown, portable Flash playing device interactive system of the present invention includes M, A, B, C, D, E, eight Flash playing devices of F, G.
At first, the user can make the needed flash interaction content of Flash playing device interaction systems in advance according to the needs of oneself, and step is as follows:
Step 200: set up the Flash film, on main Timeline, set up MovieClip object or Button object,, write respectively and both can trigger the Action Sc such as the t that create and add network after the click and order.
Step 202: set up MovieClip object or the Button object of representing the corresponding event network, as chess game, chatting platform, teaching platform etc.And both write after the click Action Script order of can trigger request creating the incident network.
Step 204: on main Timeline, set up new crucial hardwood (keyFrame), write the Action Script order that acquisition request has added the device tabulation in a certain incident network.
Step 206: on main Timeline, set up new MovieClip object or Button object, write Action Sc such as the t that trigger request adds the incoming event network list and order.
Step 208: on main Timeline, set up new crucial hardwood (key Frame), write the order that acquisition request has added the interactive network device tabulation of a certain incident network equipment.
Step 209: on the crucial hardwood that step 208 has been set up, write the order that request adds the interactive network tabulation.I.e. request adds other devices in the interactive network tabulation, and obtains appropriate address.
Step 210: newly-built MovieClip or Button object write the Action Script order of supporting that data send respectively.
Step 212: simultaneously, on main Timeline, write the ActionScript order that to carry out Data Receiving.
Step 214: according to the incident Web content, write and make the recreation the chat or the teaching cartoon scene, issue into then Flash lite version
*.swf file.
Then, the user saves as .swf form called after menu.swf simultaneously with the Flash film of making, and menu.swf is saved under the root of Flash storage card, connect this Flash storage and snap into the Flash playing device, opening power, then the micro-control unit of Flash playing device begins the menu.swf file in the control loaded Flash storage card to play frame by frame.
Wherein this Flash playing device is an embedded equipment; This flash storage card is non-volatile memory mediums such as SD card or USB flash disk.
Carrying out one to one or during one-to-many interactive:
At first, the user is by the interactive interface of Flash playing device, input operation as touch-screen or button, accept the click information of user's input, micro-control unit controls A/D converting unit in the Flash playing device is converted to coordinate figure (x with user's click information, y), and this coordinate figure sent to the Flash playing program, handle the ActionScript script that corresponding user writes by the Flash playing program;
Secondly, micro-control unit sends the Flash playing device of corresponding control request signal to correspondence successively according to the network interaction order control communication unit that user in the script writes, and the address that obtains the interactive network device is to set up interactive network.
At last, micro-control unit carries out the Flash interactive operation by the address transceive data of control communication unit to the interactive network device that obtains.Wherein, communication unit can be Zigbee, bluetooth, infrared or WiFi communication module.
Be that to specify this Flash playing device be how to set up interactive network to example with Flash chat below.
1, network is created in request, promptly determines the main frame of a MS master-slave network annexation, as shown in Figure 4 when network is created in Flash playing device M request, and be first then with it as main frame;
2, request adds network, as shown in Figure 4, other Flash playing device A, B, C, D, E, F, G, the request of all can be used as adds the slave of the network of this M establishment; And main frame M is respectively each slave and distributes the corresponding network address after this slave successfully adds network, generates one simultaneously and comprises that the request of device name and corresponding address information thereof adds the tabulation of this network equipment, shown in table 1-1;
The tabulation of table 1-1, network equipment
Device name |
Corresponding address |
M |
0x0000 |
A |
0x0001 |
B |
0x0002 |
C |
0x0003 |
D |
0x0004 |
E |
0x0005 |
F |
0x0006 |
G |
0x0007 |
3, create the incident network, promptly create the chatroom, device B (main frame M also can the create the chatroom) active request of the network of creating as main frame M as described in adding is created a chatroom, and allow other devices to add, this moment, network host M can create a device tabulation of creating the incident network, as show 1-2, writing down establishment incident network (being the chatroom herein) user's device name and unit address in the tabulation, the type of incident network is represented the chatroom as 1, and the incident network state is as allowing other user to add in 1 this incident network of expression;
Wherein, this creates incident network, can also be to create an interactive game, or interactive teaching etc., and all devices can create identical incident network, also can create different incident networks.
The device tabulation of table 1-2, establishment incident network
Device name |
Corresponding address |
The incident network type |
The incident network state |
B |
0x0002 |
1 |
1 |
4, obtain the device information of having created the incident network, promptly obtain the device list information of having created the chatroom, created the relevant information of chatroom at present to main frame M acquisition request as the A device, owing to have only B to create the chatroom in the network at present, therefore as only containing the information of device B among the table 1-2;
5, add the incoming event network, promptly add the device in the device tabulation of creating the chatroom, the address information of B device adds in the chatroom of being created by this B device as described in obtaining according to the device list information of incident network as the A device, and this moment, the A device was promptly set up man-to-man interactive network with the B device.
Wherein, other devices also can be as 4 to 5 step, obtain the device list information of having created the chatroom to main frame M, request simultaneously adds the chatroom, as shown in Figure 4, other C, D, E, F device have also added the chatroom that this B device is created, and this moment, device B can create the tabulation of a new interactive network device, as table 1-3;
Therefore, the interactive network device list information of the chatroom that the A device simultaneously can this B device of acquisition request be created, and obtain the address information of this C, D, E, F device according to this chatroom interactive network device list information, the interactive network that adding is set up by this B and C, D, E, F device, at this moment, A device and B, C, D, E, F device have been set up the interactive chat chamber of one-to-many.
The interactive network device tabulation that table 1-3, device B create
Device name |
Corresponding address |
A |
0x0001 |
B |
0x0002 |
C |
0x0003 |
D |
0x0004 |
E |
0x0005 |
F |
0x0006 |
G |
0x0007 |
Hence one can see that, the present invention is by providing a kind of interactive system and method based on the portable Flash playing device, the Flash content design can be separated with mancarried device, make between the user and can make different Flash contents as recreation, chat and teaching courseware etc. according to oneself needs flexible design, and carry out interaction, thereby realized one to one or mutual between the Flash content of one-to-many by short distance communications such as Zigbee, basket teeth; Its relative prior art has more flexibility and interactivity.And the cost of manufacture of Flash content is low, and animation effect is abundant, has good market prospects.
Certainly; the present invention also can have other various embodiments; under the situation that does not deviate from spirit of the present invention and essence thereof; those of ordinary skill in the art work as can make various corresponding changes and distortion according to the present invention, but these corresponding changes and distortion all should belong to the protection range of the appended claim of the present invention.