File tree Expand file tree Collapse file tree 2 files changed +30
-20
lines changed Expand file tree Collapse file tree 2 files changed +30
-20
lines changed Original file line number Diff line number Diff line change @@ -730,12 +730,28 @@ bool FPS_GT511C3::CaptureFinger(bool highquality)
730730
731731}
732732
733- // Gets an image that is qvga 160x120 (19200 bytes) and returns it in 150 Data_Packets
734- // Use StartDataDownload, and then GetNextDataPacket until done
735- // Returns: True (device confirming download starting)
736- // Not implemented due to memory restrictions on the arduino
737- // may revisit this if I find a need for it
738- /* bool FPS_GT511C3::GetRawImage()
733+ // Gets an image that is 258x202 (52116 bytes) and sends it over serial
734+ // Returns: True (device confirming download)
735+ bool FPS_GT511C3::GetImage ()
736+ {
737+ if (UseSerialDebug) Serial.println (" FPS - GetImage" );
738+ Command_Packet* cp = new Command_Packet ();
739+ cp->Command = Command_Packet::Commands::GetRawImage;
740+ byte* packetbytes = cp->GetPacketBytes ();
741+ delete cp;
742+ SendCommand (packetbytes, 12 );
743+ Response_Packet* rp = GetResponse ();
744+ bool retval = rp->ACK ;
745+ delete rp;
746+ delete packetbytes;
747+ GetData (52116 );
748+ return retval;
749+
750+ }
751+
752+ // Gets an image that is qvga 160x120 (19200 bytes) and sends it over serial
753+ // Returns: True (device confirming download)
754+ bool FPS_GT511C3::GetRawImage ()
739755{
740756 if (UseSerialDebug) Serial.println (" FPS - GetRawImage" );
741757 Command_Packet* cp = new Command_Packet ();
@@ -747,10 +763,10 @@ bool FPS_GT511C3::CaptureFinger(bool highquality)
747763 bool retval = rp->ACK ;
748764 delete rp;
749765 delete packetbytes;
766+ GetData (19200 );
750767 return retval;
751768
752- //return false;
753- }*/
769+ }
754770#ifndef __GNUC__
755771#pragma endregion
756772#endif // __GNUC__
Original file line number Diff line number Diff line change @@ -303,19 +303,13 @@ class FPS_GT511C3
303303#ifndef __GNUC__
304304 #pragma region -= Not implemented commands =-
305305#endif // __GNUC__
306- // Gets an image that is 258x202 (52116 bytes) and returns it in 407 Data_Packets
307- // Use StartDataDownload, and then GetNextDataPacket until done
308- // Returns: True (device confirming download starting)
309- // Not implemented due to memory restrictions on the arduino
310- // may revisit this if I find a need for it
311- // bool GetImage();
306+ // Gets an image that is 258x202 (52116 bytes) and sends it over serial
307+ // Returns: True (device confirming download)
308+ bool GetImage ();
312309
313- // Gets an image that is qvga 160x120 (19200 bytes) and returns it in 150 Data_Packets
314- // Use StartDataDownload, and then GetNextDataPacket until done
315- // Returns: True (device confirming download starting)
316- // Not implemented due to memory restrictions on the arduino
317- // may revisit this if I find a need for it
318- // bool GetRawImage();
310+ // Gets an image that is qvga 160x120 (19200 bytes) and sends it over serial
311+ // Returns: True (device confirming download)
312+ bool GetRawImage ();
319313
320314 // Gets a template from the fps (498 bytes) in 4 Data_Packets
321315 // Use StartDataDownload, and then GetNextDataPacket until done
You can’t perform that action at this time.
0 commit comments