RfidResearchGroup / ChameleonUltra

The new generation chameleon based on NRF52840 makes the performance of card emulation more stable. And gave the chameleon the ability to read, write, and decrypt cards.
https://chameleonultra.com
GNU General Public License v3.0
878 stars 147 forks source link

Implement get slot data #56

Closed domints closed 1 year ago

domints commented 1 year ago

This PR is meant to add ability to read saved slot data. At this point EM410x reading works.

I'm creating this draft PR to gather your opinion on whether fixing the mess in command IDs is an ok move (some HF commands were in LF space [5xxx]) and if changing lf em sim --id [id] to lf em sim set --id [id] and lf em sim get is ok move.

My next move will be adding support for reading out MF1 sectors from emulator memory.

domints commented 1 year ago

I will modify this feature - using it the way apps use it (calling hw slot change and getting slot data for every slot) will kill the flash quickly - it has only 10000 to 20000 write cycles endurance :O

doegox commented 1 year ago

Ha yes, good point!

domints commented 1 year ago

@doegox sorry, I was wrong, missed a line - it's storing this info only when command is issued or Chameleon goes to sleep. Either way, getting data by slot number seems more reasonable, so apps won't change user selected slot when they want to get slot data

doegox commented 1 year ago

Ha yes as you prefer. It makes more sense to not have to change selected slot to read it indeed.