Skip to content

Conversation

@floe
Copy link
Contributor

@floe floe commented Mar 17, 2016

I'm really not a Ruby expert, so perhaps there's a better way to fix the flush! issue (see second change in swd-bitbang.rb). But with these changes, everything works again for me with nRF51 & BusPirate.

Closes #9.

@floe floe changed the title fix some typos, closes #9 fix some typos (reported in issue #9) Mar 17, 2016
@floe floe changed the title fix some typos (reported in issue #9) fix name mismatches in bitbang requests (reported in issue #9) Mar 17, 2016
@floe floe changed the title fix name mismatches in bitbang requests (reported in issue #9) fix name mismatches in bitbang requests Mar 17, 2016
@corecode
Copy link
Member

Thanks, I will have a look. I think the programmer code has reached its maximum level of managable complexity and probably needs a rewrite. Until then, let's keep it together with duct tape.

if !opt[:count]
reply = @drv.transfer(req)
else
req[:count] = readcount
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From looking at cmsis-dap.rb, it seems that :count is the "new" way of passing this information...

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably we should change the bitbang driver to accept :count instead of :val

@floe
Copy link
Contributor Author

floe commented Mar 18, 2016

Swapped :val and :count, makes more sense that way.

BTW, is there any specific reason it's written in Ruby? If a rewrite is planned anyway, maybe Python would be a more widespread option?

@corecode
Copy link
Member

I am thinking of using a type safe language. Regarding popularity typescript or go seem to be reasonable options.

What do you think about those?

On March 18, 2016 12:58:41 PM GMT+01:00, Florian Echtler notifications@github.com wrote:

Swapped :val and :count, makes more sense that way.

BTW, is there any specific reason it's written in Ruby? If a rewrite is
planned anyway, maybe Python would be a more widespread option?


You are receiving this because you commented.
Reply to this email directly or view it on GitHub:
#10 (comment)

Sent from my Android device with K-9 Mail. Please excuse my brevity.

@floe
Copy link
Contributor Author

floe commented Mar 20, 2016

Hm, given those options, I'd prefer Go. More generally, I'd even suggest C++...

@floe
Copy link
Contributor Author

floe commented Mar 20, 2016

Ah damn, if you swap :val and :count, that messes up transfer_block when called from write.

@corecode
Copy link
Member

It's all a mess, especially without type safety :/ My own mess, but still a mess.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

master branch currently broken with bitbang adapter?

2 participants