24 Jun 2010

Becoming a better programmer

Recently we have started training one of our support guys, into becoming a junior developer.  It’s the 1st time we’ve trained someone on the team, who hasn’t coded commercially before.  It got me to thinking about what makes a good developer, and in turn how I can become a better developer.

I read a few other good blogs on this issue of being a better developer before starting this one.

It also got me to thinking about how I have improved at developing over my career.  Here are some of the things I’m definitely better at now than I was at university.

  • Naming of methods and refactoring.  I now use clear concise methods, both in their naming and what they do.  If you need to comment in what the method is doing, rather than that being obvious by the name, I think you are doing something wrong.
  • Becoming less likely to jump to a new technology straight away.
  • Building user interfaces that really guide the user from start to finish and require little or no introduction. SSW rules to have some great pointers here.
  • Dotting the i’s and crossing the t’s in a project, getting it deployed and not having it sit in development or ready for deployment state.
  • Searching Google (will it wasn’t there when I was at uni) but I now know when searching which paths it sends me down which are just plain ludicrous and which to follow.  Google can point you in one or two good directions when searching how to solve a coding issue, and thousands of wrong directions.

Then I started thinking, what am I worse at than I was when I came out of university.

  • Becoming less likely to learn a new technology quickly (didn’t I mention about that in the positives above) – yeah but there are pluses and minuses to it.
  • Deploying projects before they are fully ready.

My main tips to becoming a better developer

  • Name your methods and classes will, if they don’t make good sense when you are developing them, you are going to have a lot of trouble maintaining them.
  • REFACTOR REFACTOR REFACTOR!!!
  • Build user interfaces that don’t need instructions and are in the main self explanatory
  • Get involved in teaching others what tips & techniques you have acquired, this will crystallize them in your own mind and help your team.  Teaching will also show you where you are bluffing and don’t understand it, because if you don’t get it you certainly can’t explain it.
  • Learn a new technology once per month, and use it in a mini project.
  • Don’t let another member of your team become completely specialised into one technology – make sure you all have some awareness of what the other guys are coding.  My colleague is doing a WPF project, and I have no clue how it works, this shouldn’t happen.
  • Get to know the users of your software and LISTEN to them, also if possible use your software in the field.
  • Above all be passionate about coding and the software you write.

22 Jun 2010

Calibrating the cyberview scanner

 

Calibration helps fix mark sense scanning, allows you to darken images, and can get rid of unwanted lines through text.  Calibration should be done after the scanner is cleaned (for instructions on cleaning your scanner click here).  TIP: It is a good idea to do this about once a week, as blobs of build up on the scanner glass.

  • Exit Arkle epos (as you need to run EngBench, which can’t operate when Arkle has the scanner in operation).
  • Run EngBench (try running as administrator).  There should be a shortcut or your desktop (otherwise navigate to C:\Program Files\bizTech Software\Arkle – ePos\ where you will find it.


 













 

 


  • Click Cal button (to initiate calibration)

















 

 

 

 

 

  • Insert a blank sheet of A4 into scanner (leave it in scanner, it won’t automatically scan through).
  • Click OK (the scanner will now start processing the blank A4)



















 

 

 

 

  • The scanner will process the blank A4 by repeatedly pulling the paper in and out, this is normal.
  • Once this has completed, scan a few test slips and modify the light setting and gamma, until you are happy with scanned image.
  • Click OK, to save the new settings, and log back into Arkle and test the scanner there. If settings do not appear to have saved, you may not have run as administrator or have correct permissions to save files to the Arkle ePos folder.

8 Jun 2010

Fixes

Fixes in 2.5.41 and above

Monitored Customers

  • View detailed monitored customer report, and view all their slips (Reports | Profit Loss | Stake Payout Profit | By Monitored Customer, Sport
  • You can now remove a slip from monitored customer, select other slip details tab, and click the delete button beside monitored customer, this sets bet slip back to no monitored customer.
  • Hide an old inactive customer, so they don’t show up in monitored customer list.
    In the edit customer Form change their status to “Hidden”
  • Bet Slip Actions | Refresh customer list (refreshes added customers, so you no longer have to log out and back in).
  • On the F8 screen you can see monitored customer ID column to easily identify which slips are monitored and which are not.

Bet Slip Editor

  • Bet Slip Actions | Remove all bets (deletes all bets from slip in one go)

Bug Fixes

  • Remove bug allowing re-edit of void bet slips.
  • Lotto entry, tab order fixed
  • Ctrl + C, fixed bug (was previously copying unselected selections)

A new BETA version is out to selected shops for testing.
As this was a complete rewrite of the internals of Arkle ePos, a lot of functions fell off the radar and were not included.  We are added them back in one by one and doing daily mini-releases to installed shops.

For a list of what is new and improved in the new slip editor click here

Below is a list of the BETA versions and the missing features they fix

  • 2.5.33 : Added ctrl + S (soccer), Ctrl + O (golf), Ctrl + D (draw)
  • 2.5.33 : Fixed with on editing alert, so you can now easily see whole alert, no matter how large it is.
  • 2.5.32 (BETA) | F4 (settle slip) + Add wager to slip, vastly speeded up (by removing event handlers that seemed to be firing all over the place
  • 2.5.32 (BETA) | Event Liabilities + Accumulator Liabilities re-added.
  • 2.5.32 : Changes to speed up F4 etc... by not firing events
  • 2.5.27 (BETA) | Almost Ready For Release to BETA Shops

F5 Check for prices defaults to entering next selection after each price checked
Market Book Summary | View Slips (working again)
F8 | Search Slips By Selection name 

Problem: If you enter a bet by the race time / selection number, it doesn't go straight to the stake screen anymore, it defaults back to the name selection editor. 
2.5.27 BETA changes this behaviour if you enter 2 or more by number it goes to stake, otherwise goes back to selection number (this is by design)

· When entering lotto, It defaults to the draws e.g. lunchtime draw, teatime draw etc. it should default up at the game type then if you press tab it should bring you down to the draws then to 6 or 7 nums and then to enter the numbers.
Shift tab should work for this on 2.5.27 BETA (as most times you are going to be entering consecutive same game types)

Edit after Actual Off Alert, doesn’t include the length of the race.
Should be fixed in 2.5.26 BETA

Arkle Feed 2.1.14, fixes slow settling of losers, which can slow payout if a bet has one loser and one winner on a race just gone

26 May 2010

My Fav Blogs

Going to keep a list here of my fav bugs & online posts

My all time favourite (a toss up by SSW rules & How to report bugs effectively)

How to Report Bugs Effectively
by Simon Tatham, professional and free-software programmer



SSW Rules to better



Scott Hanselman : Tools List

Beth Massi's blog (excellent stuff)



Non IT Related

Belfast food reviews

19 May 2010

New Selection Editor Tips

None Slip editing enhancements (this update is mainly enhancements to slip editor although a few bugs have been fixed).

  • Entry of Irish Lotto Results from SIS (fixed)
  • Entry of 49s Results from SIS (fixed)
  • Settling of Fav/2nd Fav (fixed)

Enhancements to bet slip editor

  • Warnings on no rule4 applied before payout
  • Warnings on amended result before payout
  • Warnings on Stewarts Enquiries or Objections before payout

See bottom of document for screenshots.


The new results viewer is much easier on the eye


  • Dead heats/Co Favs etc... highlighted in yellow

What you will notice 


  • Some new shortcut keys (so it may take a bit of getting used too) 
  • Switching sports (e.g. Ctrl + L is much faster)
  • Filtering when typing selection names is much faster
  • Numbers editor defaults to forty nines upon login, and then last edited numbers game, for subsequent ctrl + N calls until you log back out. 

Ctrl + E will return you to text entry textbox at any time (without having to refresh coupon)
Tip: You would use this if you had clicked elsewhere, and wanted to go back to editing another selection

If using the arrow up and down to enter a selection, use "+" key on keyboard to add that particular selection (rather then the enter key)

Entering Dogs/Horses by time & number (of fav)
Tab over to the time filter text box

  • You can filter time by entering exact time (e.g. 3.05) or if you just enter 3 (it will show all races between 3pm & 4pm – and you can use up down arrow to select).  If only one race is shown the Market list box will go green. 
  • If more than one race matches your search criteria use the up down arrows (or mouse) to select appropriate race.
  • Once you are happy with the race click [Space] or [Tab] and enter your numbers of favourites
    • 2 3 (will select numbers 2 & 3)
    • 2 f (will select number 2 & the favourite)
    • 2 2f (will select number 2 & the second favourite)

How was this achieved in code?
  • Enhanced reading from database (using stream data instead of database tables)
  • Local caching of data, to prevent database calls, if stream data is not updated
  • Enhanced filtering during editing using LINQ instead of dataview

    Screenshot | 1 (Amended result + no rule 4 warning)

    R4 Missing & Amended result

    New Results Viewer

    18 May 2010

    DatagridView : Sort Generic List on any property (minimal code)

    Had been wrecking my head with this for a few hours but got a good solution (with very little code).
    Okay so it using reflection and mightn't have order log n speed, but so what if you are sorting collections with normally less than 50 items.

    I handle the Column Header Mouse Click
    Get the data property name.
    Then use some reflection to sort the generic list.  (before this I had to use select case, and sort by knowing the property name in code, but when I add new properties this was a pain to maintain).


        Private Sub SelectionsCollectionsDataGridView_ColumnHeaderMouseClick(ByVal sender As Object, ByVal e As System.Windows.Forms.DataGridViewCellMouseEventArgs) Handles SelectionsCollectionsDataGridView.ColumnHeaderMouseClick
            Try
                Dim col = Me.SelectionsCollectionsDataGridView.Columns(e.ColumnIndex)
                Me.selectedMarket.SelectionsCollections.Sort(Function(p1, p2) p1.GetType.GetProperty(col.DataPropertyName).GetValue(p1, Nothing).CompareTo(p2.GetType.GetProperty(col.DataPropertyName).GetValue(p2, Nothing)))
                Me.SelectionsCollectionsBindingSource.CurrencyManager.Refresh()
            Catch ex As Exception
                MsgBox(ex.ToString, MsgBoxStyle.Critical)
            End Try
        End Sub

    24 Apr 2010

    In Running Betting

    bizTech Software are pleased to announce in-running betting is now available in arkle bet POS.

    • Display in running on arkle betting screens in your shop.
    • Edit in running bets on arkle ePos, and view full price change history, in your ePos and online.
    • Prices automatically update and suspend in real time.

    Sports Available

    • Football
      • Match betting, next goalscorer, correct score, match handicaps.
    • Snooker, Tennis, Golf (and more sports coming soon).