sportstracker icon indicating copy to clipboard operation
sportstracker copied to clipboard

Device importer interface

Open ssaring opened this issue 18 years ago • 5 comments

Hi.

Just to get a discussion started.

I would like to add some functionality to directly import data from the Polar RS200SD device (through the use of rs200_decode). For that we need some common interface for all importers. Just to get started I suggest something along the lines of the attached interface.

Any comments?

/Jacob

Reported by: jacobilsoe

ssaring avatar Oct 23 '06 17:10 ssaring

IDeviceImporter.cs

Original comment by: jacobilsoe

ssaring avatar Oct 23 '06 17:10 ssaring

Logged In: YES user_id=1118995

Hi Jacob,

I move this discussion thread to the feature requests...

Stefan

Original comment by: ssaring

ssaring avatar Oct 25 '06 17:10 ssaring

Logged In: YES user_id=1118995

Hi Jacob,

just my comments to your proposal: We should also add a method which lists the available downloadable exercises of the device, also when it's not supported by all models. The Import() (or better Download()) method needs to get the index of the exercise file (from the list) to download. This index can be 0 when the device doesn't support that list. We also need to add the ability to delete the selected exercises from the list at the device. I know this is also not supported by all devices.

Maybe it would be good to have Methods or Attributes which returns True when the List and the Delete features are supportet by the Importer implementation.

What do you think?

Bye, Stefan

Original comment by: ssaring

ssaring avatar Oct 25 '06 17:10 ssaring

Logged In: YES user_id=2170644 Originator: NO

Hello, I actually have all components required to decode CS200 data from a microphone written in Java. Some code cleaning is needed and integration to UI. I have ported rs200_decode audio demodulator and segment handling parts to Java and implemented CS200 data format parser. Code is running but not as clean as it should be. I will drop patch when I have some time to clean the code.

Original comment by: antpata

ssaring avatar Aug 06 '08 11:08 ssaring

Logged In: YES user_id=1118995 Originator: NO

Hi 'antpata',

great, sounds very interesting. How do you access the microphone in Java? Via I/O-operations on the /dev/ filesystem? Or do you use native code (JNI)?

What's the result of the import? The exercise file on the filesystem or a PVExcercise object or a SportsTracker Exercise object?

As discussed many times before: we will not directly add specific importer features to SportsTracker/PolarViewer. So you also need to provide a generic interface for all future importers and your specific implementation. The GUI must only use this generic importer interface, it must not know your specific implementation! You should take a look how this problems has been solved for the ExerciseParser's.

Bye, Stefan

Original comment by: ssaring

ssaring avatar Aug 07 '08 19:08 ssaring