ISISComputingGroup / IBEX

Top level repository for IBEX stories
4 stars 2 forks source link

GALIL: allow `COM` in `GALILADDR` macro #8218

Closed FreddieAkeroyd closed 5 months ago

FreddieAkeroyd commented 5 months ago

As a user i would like to be able to type COM4 38400 as well as 192.168.1.1 into the GALILADDR macro

Acceptance Criteria

How to Test

rerpha commented 5 months ago

Looks good - could you patch onto galil-old of ioc\master please, I guess we'll need this there as well

FreddieAkeroyd commented 5 months ago

Thanks @rerpha in fact probably more important in galil-old than where it is currently

rerpha commented 5 months ago

Just a thought, as I think this works fine for the short term, but perhaps long term we should do something similar to the CCD where we have a baud rate macro which has no default, then do a stringiftest to see if it exists then set up serial comms if so? And allow PORT to either be an IP or COMx

just thinking this might be less confusing for users as they might not be able to decipher the regex

FreddieAkeroyd commented 5 months ago

That would be simpler to a user, but ideally a user would not see the regex at all and would just see an example of that to type (an example attribute in the XML). Having PORT as COM or IP would still be a bit of a horrible regex for a user, i see the CCD has separate PORT and IPADDR macros. I see a bit of an issue using BAUD from a working point of view, we have to say it had no default if we are using it as a check, but then we don't want to make it mandatory as that means COM not IP. So i can see how the mechanism would work, but just our current wording may be a bit confusing.